import requests
import os

def DownloadImageByUrl(url, name):
      print(url)
      resp = requests.get(url, timeout=1)
      if resp.status_code != 200:
          return resp.status_code
      with open(name, "wb") as f:
            f.write(resp.content)
      return resp.status_code
def DeletePhotoByPath(path):
      os.removedirs(path)
